<?
// Page variables
$rightCol   = 1;
include("includes/functions.php"); 

// Get conference records
$sqlC = "SELECT * from transConferences WHERE Active = '1' ORDER BY DateStart";
$resultC = mysql_db_query($dbname,$sqlC);
$rows = mysql_num_rows($resultC);

include("includes/header.php"); ?>
	<div id="pageTop"></div>
	<div id="pageContent">
		<? include("includes/menu_main.php"); ?>
		
		<div id="rightCol">
			<img src="images/rightColTop.gif">
			<? include("includes/rightCol.php");  ?>
		</div>
		
		<div id="mainContent">
			<h1>Conferences and Events</h1>
		
			<p>
			<ul class="ulMain">	
				<?
				if ($rows>0) {
					while ($value = mysql_fetch_assoc($resultC)) {
						$dateStart = mysql_to_date2($value[DateStart]);
						$dateEnd   = mysql_to_date2($value[DateEnd]);
						$title     = stripslashes($value[Title]);
						$desc      = stripslashes($value[ConfDescription]);
						$url       = $value[ConfLink];
						echo "<li>\n";
						echo "<b>$title</b><br />\n";
						echo "<span class=\"date\">".$dateStart;
						if (!empty($dateEnd) && ($dateEnd != '00 00, 0000')) {
							echo " to ".$dateEnd;
						}
						echo "</span><br />\n";
						if (!empty($desc)) { echo $desc; }
						
						if (!empty($url)) { echo "<p class=\"web\"><a href=\"$url\" target=\"_blank\" title=\"Visit Event Website\">Visit Event Website</a></p>"; }
						
						echo "</li>\n";
					}
				} else {
					echo "<li>There are no conferences or events at this time.</li>\n";
				}
				?>
			</ul>
			</p>
			
			<div class="spacer2" style="height: 800px;"></div>
		</div>
		
	</div>
<? include("includes/footer.php"); ?>